﻿using System.Net.Http;
using System.Text;
using System.Text.Json;
using JetBrains.Annotations;

namespace Linker.TaskCenter.Http
{
    public class JsonContent : StringContent
    {
        public JsonContent([NotNull] object content) : base(JsonSerializer.Serialize(content), Encoding.UTF8,
            "application/json")
        {
        }


        public JsonContent(string content) : base(content, Encoding.UTF8, "application/json")
        {
        }
    }
}